]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
overviewControls: Add "gesture-in-progress" property on the state adjustment
authorCarlos Garnacho <carlosg@gnome.org>
Thu, 11 Feb 2021 23:20:31 +0000 (00:20 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Wed, 17 Feb 2021 13:06:11 +0000 (14:06 +0100)
This will be set whenever an event controller is manipulating the adjustment.
It should enter the same transitional state it does for animations. This
will be used by the overview gesture.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>

js/ui/overviewControls.js

index 32388621e9e24fc5c68c4f27a15d3b7e84e870f5..f43d8e236eda6940894f04643a63777096897538 100644 (file)
@@ -195,8 +195,14 @@ class ControlsManagerLayout extends Clutter.BoxLayout {
     }
 });
 
-var OverviewAdjustment = GObject.registerClass(
-class OverviewAdjustment extends St.Adjustment {
+var OverviewAdjustment = GObject.registerClass({
+    Properties: {
+        'gesture-in-progress': GObject.ParamSpec.boolean(
+            'gesture-in-progress', 'Gesture in progress', 'Gesture in progress',
+            GObject.ParamFlags.READWRITE,
+            false),
+    },
+}, class OverviewAdjustment extends St.Adjustment {
     _init(actor) {
         super._init({
             actor,
@@ -231,7 +237,7 @@ class OverviewAdjustment extends St.Adjustment {
             : 1;
 
         return {
-            transitioning: transition !== null,
+            transitioning: transition !== null || this.gestureInProgress,
             currentState,
             initialState,
             finalState,